<template>
	<view class="page">

		<view class="page__bd">

			<view class="cont-block">
				<block v-for="(item,index) in itemList" wx:key="item">
					<view class="cont-list" :class="currentTab == index ? 'listActive' : ''" :data-id="index" @tap="tab">
						<view class="newstabBar" :class="currentTab==index?'listActiveWhite':'listActiveWhite'">
							<text v-if="item.index<3">同城</text>
							<text v-if="item.index==3">附近</text>
							<text>{{item.name}}</text>
						</view>
					</view>
				</block>
			</view>

			<view class='weui-tab'>

				<view class='weui-navbars'>
					<view class='weui-navbar-list' @tap='navbarTab' data-id="0">
						<text :class="navbarIndex == 0 ? 'mytick' : 'square'"></text>
						<text :class="navbarIndex == 0 ? 'navbar-act' : ''">所有工人</text>
					</view>
					<view class='weui-navbar-list' @tap='navbarTab' data-id="1">
						<text :class="navbarIndex == 1 ? 'mytick' : 'square'"></text>
						<text :class="navbarIndex == 1 ? 'navbar-act' : ''">{{navbarWorkerName}}</text>
					</view>
					<view class='weui-navbar-list' @tap='navbarTab' data-id="2">
						<text :class="navbarIndex == 2 ? 'mytick' : 'square'"></text>
						<text :class="navbarIndex == 2 ? 'navbar-act' : ''">{{orderPlaceName}}</text>
					</view>
				</view>


				<view class='navbar-banner' v-if="userInfo.type==1" @tap='showUserModal'>
					<image src='https://gy-files.oss-cn-shenzhen.aliyuncs.com/picture/fujin.png'></image>
				</view>

				<view class='card'>
					<image class='card-img' src='https://gy-files.oss-cn-shenzhen.aliyuncs.com/picture/tab_my/card-back.jpg'></image>
					<image class='address-card-wx' :data-id="userInfo.id" :data-name="userInfo.name" @tap='bindEwm' src='https://gy-files.oss-cn-shenzhen.aliyuncs.com/picture/tab_my/card-wx.png'></image>
					<view class='card-block'>
						<view class='card-block-head' @tap='openCard' :data-id="userInfo.id">
							<view class='card-block-head-top'>
								<image v-if="userInfo.newAvatarUrl" class='block-head-img' :src="userInfo.newAvatarUrl"></image>
								<image v-else class='block-head-img' :src="userInfo.avatarUrl ? userInfo.avatarUrl : defaultAvatar"></image>
								<view class='block-head-user'>
									<view class='block-head-user-name'>
										<view class='block-head-user-name-title'>{{userInfo.name}}</view>
										<view class='user-level-img'>
											<text class='user-level-text-mobile'>{{userInfo.mobile}}</text>
										</view>
									</view>
									<view class='block-head-user-workCategory'>
										<text v-if="userInfo.workCategory.name">{{userInfo.workCategory.name}}</text>
										<text v-if="userInfo.secondary.name">{{userInfo.secondary.name}}</text>
									</view>
								</view>
							</view>
							<view class='card-block-head-address'>
								<image class='address-card-host' mode='scaleToFill' src='https://gy-files.oss-cn-shenzhen.aliyuncs.com/small_img/weizhi.png'></image>
								<text class='address-card-name'>{{userInfo.address}}</text>
							</view>
						</view>

						<view class='card-line-btn'>

							<view class='line-btn-editinfo' @tap='editCard' :data-id="userInfo.id">
								<image src='https://gy-files.oss-cn-shenzhen.aliyuncs.com/small_img/huiyuan.png'></image>
								完善名片
							</view>

							<view class='line-btn-collect' @tap='openInvitation' :data-id="userInfo.id">
								<image src='https://gy-files.oss-cn-shenzhen.aliyuncs.com/small_img/renqi.png'></image>
								<text>人气{{status.has_come}}</text>
							</view>
							<button class='line-btn-card' @tap='openCard' :data-id="userInfo.id">
								<image src='https://gy-files.oss-cn-shenzhen.aliyuncs.com/small_img/fenxian.png'></image>
								查看名片
							</button>
						</view>
					</view>

				</view>
				<view class="weui-tab__panel" style='padding-top:10upx;'>
					<view class='earby-panel'>
						<view class='earby-list' v-for="(item,index) in nearbyList" wx:key="index">
							<navigator :url="'../user-center/my-info/cardcase/cardcase?id='+item.id" hover-class="none">
								<view class='earby-list-top'>
									<view class='earby-list-top-img'>
										<image :src="item.avatarUrl"></image>
									</view>
									<view class='earby-list-top-right'>
										<view class='earby-list-top-right-name'>
											<text class='name-auto' v-if="item.name">{{item.name}}</text>
											<block v-if="item.viplever_id == 0">
												<image class="icon-star vip-star" src="/static/images/user-center/4level-dark.png"></image>
												<image class="icon-star vip-star" src="/static/images/user-center/4level-dark.png"></image>
												<image class="icon-star vip-star" src="/static/images/user-center/4level-dark.png"></image>
											</block>
											<block v-if="item.viplever_id == '1'">
												<image class="icon-star vip-star" src="/static/images/user-center/4level-light.png"></image>
												<image class="icon-star vip-star" src="/static/images/user-center/4level-dark.png"></image>
												<image class="icon-star vip-star" src="/static/images/user-center/4level-dark.png"></image>
											</block>
											<block v-if="item.viplever_id == 2">
												<image class="icon-star vip-star" src="/static/images/user-center/4level-light.png"></image>
												<image class="icon-star vip-star" src="/static/images/user-center/4level-light.png"></image>
												<image class="icon-star vip-star" src="/static/images/user-center/4level-dark.png"></image>
											</block>
											<block v-if="item.viplever_id == 3">
												<image class="icon-star vip-star" src="/static/images/user-center/4level-light.png"></image>
												<image class="icon-star vip-star" src="/static/images/user-center/4level-light.png"></image>
												<image class="icon-star vip-star" src="/static/images/user-center/4level-light.png"></image>
											</block>
										</view>
										<view class='earby-list-top-right-level'>
											<text class='craft' v-if="item.work_category_id">{{item.work_category_id}}</text>
											<text class='craft' v-if="item.secondary_work_category_id">{{item.secondary_work_category_id}}</text>
											<text class='craft' v-else-if="!item.work_category_id && !item.secondary_work_category_id">暂无工种</text>
										</view>
										<view class='earby-list-top-right-host'>
											<image src='/static/images/contact-us/loc.png'></image>
											<text class='mar-auto'>{{item.address}}</text>
											<text class=''>{{item.distance}}KM</text>
										</view>
									</view>
								</view>
							</navigator>
							<view class='earby-list-bottom'>
								<view class='earby-list-bottom-list' :data-id="item.id" :data-tel="item.mobile" @tap='phonecallevent'>
									<text>拨打电话</text>
									<image src='https://gy-files.oss-cn-shenzhen.aliyuncs.com/small_img/contact-us/tel.png'></image>
								</view>
								<navigator :url="'../user-center/my-info/cardcase/cardcase?id='+item.id" hover-class="none" class='earby-list-bottom-list'>
									<text>查看详情</text>
									<image class='img' src='https://gy-files.oss-cn-shenzhen.aliyuncs.com/picture/nearby_check.png'></image>
								</navigator>
								<navigator :url="'../user-center/my-info/cardcase/cardcase?id='+item.id" hover-class="none" class='earby-list-bottom-list'>
									<text>查看名片</text>
									<image class='img' src='https://gy-files.oss-cn-shenzhen.aliyuncs.com/picture/nearby_rep.png'></image>
								</navigator>
							</view>
						</view>
					</view>
				</view>



			</view>

			<view class='weui-tab' v-if="currentTab == 2">

				<view class='room-box dp-flex-arround' @tap="roomdtlTap" :data-id="item.roomid" :data-address="item.chat_room_address"
				 :data-name="item.name" :data-viewId="item.id" :data-tid="item.tid" v-for="(item,index) in chatList" wx:key="index">
					<view class='left'>
						<view class='room-title'>{{item.name}}</view>
						<image class='room-img' :src="item.chat"></image>
					</view>
					<view class='right'>
						<image :src="item.cover" class="right-imgs" />
					</view>
				</view>

			</view>

		</view>

		<!-- 查看订单弹框 -->
		<view class='check-pop' v-if="successfulOrderPop" catchtouchmove="ture">
			<view class='check-cover'></view>
			<view class='check-succ'>
				<view class='check-slose' @tap='solseOrder'>
					<image src='../../static/images/slose-order.png'></image>
				</view>
				<view class='check-succ-header'>
					<image src='../../static/images/dui.png'></image>
				</view>
				<view class='check-succ-tit'>发单成功</view>
				<view class='check-succ-red'>
					<image src='../../static/images/hb.png'></image>
					<view> <text style='color:#f94c48;'>3人拨打该订单</text>您能获得5元红包</view>
				</view>
				<view class='check-succ-accept'>
					<image src='../../static/images/wx.png'></image>
					<view>领奖方式:加客服微信<text style='color:#f94c48;'>13007489696</text>核实后给您发<text style='color:#f94c48;'>微信红包</text></view>
				</view>
				<navigator :url="'../order-lists/order-detail/order-detail?id='+orderId" class='check-succ-nav'>
					<image src='../../static/images/order-fff.png'></image>查看订单并可查看到群
				</navigator>
			</view>
		</view>
	</view>
</template>

<script>
	import app from '../../App.vue';
	import {
		GYZJMODEL as gyzjModel
	} from '../../utils/gyzjModel.js'
	export default {
		data() {
			return {
				itemList: [
					// { naffffme: '找附近的工人', index: 1 },
					{
						name: '工友',
						index: 0
					},
					{
						name: '商家',
						index: 1
					},
					{
						name: '设计师',
						index: 2
					},
					{
						name: '工友',
						index: 3
					}
					// { name: '找附近工人', index: 1 },
					// { name: '同城万人群', index: 2 },
				],
				earby_radio: [{
						name: '所有工人',
						value: '所有工人',
						checked: 'ture'
					},
					{
						name: '筛选工种',
						value: '筛选工种'
					},
					{
						name: '筛选老乡',
						value: '筛选老乡'
					},
				],
				currentTab: 3,
				vipLevel: [],
				tabs: ["【找点工】", "【找包工】", "【找施工队伍】", "【商家】"],
				tabs_radio: [{
						name: '找点工',
						value: '找点工',
						checked: 'ture'
					},
					{
						name: '找包工',
						value: '找包工'
					},
					{
						name: '找队伍',
						value: '找队伍'
					},
					{
						name: '找商家',
						value: '找商家'
					},
				],
				nearbyList: [], //附近工人列表
				// tab切换状态
				activeIndex: 0,
				sliderOffset: 0,
				sliderLeft: 0,
				successfulOrderPop: false, //发单成功弹框
				orderId: '', //订单ID
				files: [],
				chooseMainWorker: '', // 选择工种一级大类
				chooseDetailWorker: '', // 选择工种二级类别
				workerName: "", // 当前选择的工种名字
				showView: true,
				//籍贯相关
				birthIndex: [],
				birthArray: [],
				native_province_id: '',
				native_city_id: '',
				native_district_id: '',
				// 工程地点
				consPlace: '',
				province_id: '',
				city_id: '',
				district_id: '',
				detailLoc: '',
				longitude: '',
				latitude: '',
				// 需求人数
				needsPeople: ['1', '2', '3', '4', '5'],
				needsPIndex: 0,
				need_amount: 1,
				// 开工日期
				startDate: '',
				startDateDetail: '09:00',
				// 是否加班
				isOvertime: 2,
				overtime_money: '',
				// 施工队规模
				teamSizeList: {},
				teamSizeIndex: 0,
				teamSizeId: 1, // 当前选择的施工队规模的id，默认5-10人
				// 省市区数据
				provinceList: [],
				cityList: [],
				//诚信金额
				index: 1,
				//是否面议
				items: [{
					name: false,
					value: '否',
					checked: false
				}, ],
				ceshi: '',
				textArea: 0, //文字数
				// 诚信金金额
				integrityAmount: '',
				contractorMoney: '',
				teamShouldPay: '',
				notFirstTime: true,
				// 施工队地区
				curOrderRegion: 0,
				provinceLists: [],
				curChooseArr: [], // 当前选择可抢单区域的id
				interval: '', //定时器
				//搜索工人列表参数
				work_category_id: "",
				navbarWorkerName: '筛选工种',
				native_order_id: '',
				orderPlaceName: '筛选老乡',
				navbarIndex: 0,
				isShowUserModal: false,
				isBanner: true,
				title: '',
				categoryMainId: '', //商家id
				categoryMainName: '', //商家名称
				// 群组
				chatList: '',
				roomName: '',
				viewId: '',
				teamId: '',
				city: "",
				userInfo: '',
				status: '', //获取人气
			}
		},
		methods: {
			/*还未入驻跳转,知道类型是1,其他不知,有数据,判断有无token,无token还是跳登录,有则跳入驻*/
			showUserModal:function(){
				/**/
				if(app.globalData.token){
					if(app.globalData.userInfo.mobile){
						gyzjModel.prototype.showUserModal('../vip-info/vip-info');
					}else{
						gyzjModel.prototype.showUserModal('../ads/fill-phone/fill-phone');
					}
				}else{
					let arr=this.main_getGlobal();
					this.main_is_login(arr);
					if(arr.token=='0739'){
						return false;
					}
				}
			},
			// 拨打电话（限制次数5次)
			phonecallevent: function(e) {
				let arr=this.main_getGlobal();
				this.main_is_login(arr);
				if(arr.token=='0739'){
					return false;
				}
				let _this = this;
				let postData = {
					call_user_id: e.currentTarget.dataset.id
				}
				gyzjModel.prototype.callWorker(postData, arr.token, arr.type).then(res => {
						uni.showLoading({
							title: '正在拨号中...',
						})
						switch (res.code) {
							case 1:
								setTimeout(() => {
									uni.hideLoading()
									uni.makePhoneCall({
										phoneNumber: e.currentTarget.dataset.tel,
										success() {}
									})
								}, 1000)
								break;
							default:
							if(res.message==''){
								console.log('res的data',res);
								uni.showToast({
									title: res.data,
									icon: 'none'
								})
							}else{
								console.log('res的message',res);
								uni.showToast({
									title: res.message,
									icon: 'none'
								})
							}
								uni.hideLoading();
								break;
						}
				});
		},
		//分享打开自己的名片
		openCard: function() {
			uni.navigateTo({
				url: '../user-center/my-info/cardcase/cardcase?id=' + this.userInfo.id,
			});
		},
		//修改自己的名片
		editCard: function() {
			let arr=this.main_getGlobal();
			this.main_is_login(arr);
			if(arr.token=='0739'){
				return false;
			}
			uni.navigateTo({
				url: '../user-center/my-info/my-info',
			});
		},
		//跳转自己的邀请成功
		openInvitation: function() {
			uni.navigateTo({

				url: '../user-center/my-invite-list/my-invite-list?type=1',
			});
		},
		// 获取施工队诚信金
		getContractorMoney: function() {
			gyzjModel.prototype.getContractorMoney().then(data => {
				switch (data.code) {
					case 1:
						uni.hideLoading();
						this.teamSizeList = data.data;
						this.teamShouldPay = data.data[0]['money'];
						this.teamSizeId = data.data[0]['id'];
						break;
					default:
						uni.hideLoading();
						uni.showToast({
							title: data.message,
							icon: 'none'
						});
						break;
				}
			});
		},
		/*点击切换导航栏*/
		tab: function(e) {
			let id = e.currentTarget.dataset.id,
				type = 0;
			console.log(e);
			console.log('首页id' + id);
			if (id == 0) {
				type = 3;
				console.log('id为0进来');
				uni.navigateBack();
			} else if (id == 1) {
				type = 4;
				console.log('id为1进来');
				uni.navigateBack();
			} else if (id == 2) {
				console.log('id为2进来');
				type = 5;
				uni.navigateBack();
			}
			let pages = getCurrentPages();
			let prevPage = pages[pages.length - 2];
			//id为3不处理
			//如果id为0或1或2的时候跳首页的处理
			if (id == 0 || id == 1 || id == 2) {
				if (id == '1') {}
				prevPage.$vm.mapCtx.getCenterLocation({
					success: (res) => {
						console.log('我是res的值');
						console.log(res);
						if (res.latitude == 0 && res.longitude == 0) return;
						prevPage.$vm.getNearbyWorker(res.longitude, res.latitude, type);
					}
				})
			}
			prevPage.$vm.currentTab = id;
		},
		/*点击事件*/
		tabClick: function(e) {
			this.sliderOffset = e.currentTarget.offsetLeft;
			this.activeIndex = e.currentTarget.id;
		},
		workerFilter: function() {
			if (this.workerName) {
				this.navbarWorkerName = this.workerName;
			}
			if (this.orderPlaceName) {
				this.orderPlaceName = this.orderPlaceName;
			}
			let arr = this.main_getGlobal();
			var postData = {
				category_id: this.work_category_id,
				ctiy_id: this.native_order_id
			}
			let that = this;
			gyzjModel.prototype.getnearbyWorkList(postData, arr.token, arr.type).then(data => {
				switch (data.code) {
					case 1:
						Array.prototype.delete = function(delIndex) { //按钻石会员排序
							var temArray = [];
							for (var i = 0; i < this.length; i++) {
								if (i != delIndex) {
									temArray.push(this[i]);
								}
							}
							return temArray;
						}
						var data = data.data.data;
						var a = [],
							b = [];
						for (var i = 0; i < data.length; i++) {
							if (data[i].viplever_id == '1') {
								a.push(data[i]);
								b.push(i)
							} else if (data[i].viplever_id == '2') {
								a.push(data[i]);
								b.push(i)
							} else if (data[i].viplever_id == '3') {
								a.push(data[i]);
								b.push(i)
							}
							var str = data[i].distance.substr(0, 5);
							data[i].distance = str;
						}
						for (var i = 0; i < b.length; i++) {
							data = data.delete(b[i]);
						}
						for (var i = 0; i < a.length; i++) {
							data.splice(0, 0, a[i])
						}
						that.nearbyList = data;
						break;
					default:
						uni.showToast({
							title: data.message,
							icon: 'none'
						})
						break;
				}
			});
		},

		/*筛选*/
		navbarTab: function(e) {
			var id = e.currentTarget.dataset.id;
			this.navbarIndex = e.currentTarget.dataset.id;
			if (id == '1') {
				uni.navigateTo({
					url: '../vip-info/worker-type/worker-type?cat=indexBirth',
				})
			} else if (id == '2') {
				uni.navigateTo({
					url: '../city-choose/city-choose?pageType=navbarRelease',
				})
			} else {
				this.getnearby();
				this.data.work_category_id = '';
				this.data.navbarWorkerName = '筛选工种';
				this.data.orderPlaceName = '筛选老乡';
				this.data.native_order_id = '';
				this.navbarWorkerName = '筛选工种';
				this.orderPlaceName = '筛选老乡';
			}
		},
		
		// 获取附近工人列表
		getnearby: function() {
			let arr = this.main_getGlobal();
			let that = this;
			console.log('附近的工人进来');
			gyzjModel.prototype.getnearbyList(arr.token, arr.type).then(data => {
				console.log('附近的工人的值', data);
				switch (data.code) {
					case 1:
						Array.prototype.delete = function(delIndex) { //按钻石会员排序
							var temArray = [];
							for (var i = 0; i < this.length; i++) {
								if (i != delIndex) {
									temArray.push(this[i]);
								}
							}
							return temArray;
						}
						var data = data.data.data;
						var a = [],
							b = [];
						for (var i = 0; i < data.length; i++) {
							if (data[i].viplever_id == '1') {
								a.push(data[i]);
								b.push(i)
							} else if (data[i].viplever_id == '2') {
								a.push(data[i]);
								b.push(i)
							} else if (data[i].viplever_id == '3') {
								a.push(data[i]);
								b.push(i)
							}
							var str = data[i].distance.substr(0, 5);
							data[i].distance = str;
						}
						for (var i = 0; i < b.length; i++) {
							data = data.delete(b[i]);
						}
						for (var i = 0; i < a.length; i++) {
							data.splice(0, 0, a[i])
						}
						that.nearbyList = data;
						break;
					default:
						uni.showToast({
							title: data.message,
							icon: 'none'
						})
						break;
				}
			});
		},
		/*获取附近的人*/
		getMySubordinate: function(cat, loadMore) {
			var arr = this.main_getGlobal();
			console.log('arr的值', arr);
			gyzjModel.prototype.getMySubordinate(cat, arr.token, arr.type).then(res => {
				console.log('获取的邀请的人的res的值', res);
				this.status = res.data.countArr;
				uni.hideLoading();
			})
		},
	},
	onLoad() {
			//获取人气
			this.getMySubordinate(0);
			//获取附近的人等
			this.getnearby();
			var that = this;
			uni.getSystemInfo({
				success: function(res) {
					that.sliderLeft = (res.windowWidth / that.tabs.length - sliderWidth) / 3;
					that.sliderOffset = res.windowWidth / that.tabs.length * that.activeIndex;
					console.log(that.sliderLeft)
					console.log(that.sliderOffset)
				}
			});
			//发单诚信金，已经不用
			// this.getContractorMoney();
			this.getReginList(0).then((res) => {
				this.provinceLists = res;
			})
		},
		onShow: function(options) {
			// 加入callback，处理异步请求
			let userInfo = app.globalData.userInfo;
			this.userInfo = userInfo;
		},
	}
</script>

<style>
	@import url("../../static/style/app.css");

	.page {
		width: 100%;
		height: 100%;
		position: relative;
	}

	.section {
		display: flex;
		flex-direction: column;
		margin-top: 20upx;
		background-color: #fff;
	}

	.cancel-before-content::before {
		border-top: 0px;
	}

	.display-column {
		display: flex;
		flex-direction: column;
		flex: 1;
	}

	.left-container {
		/* color: #666; */
		padding-left: 30upx;
		flex: 1;
	}

	.weui-cell__hd__img {
		width: 18px;
		height: 18px;
		margin-right: 10px;
		display: inline-block;
	}

	.weui-cell__hd__img160 {
		width: 16px;
		height: 16px;
		margin-right: 10px;
		display: inline-block;
	}

	.weui-cell__hd__img200 {
		width: 20px;
		height: 20px;
		margin-right: 10px;
		display: inline-block;
	}

	.red-color {
		color: #f94c48;
	}

	.right-container {
		flex: 3;
	}

	.section-wrap {
		position: relative;
		display: flex;
		align-items: center;
	}

	.pad-0 {
		padding: 0;
	}

	.visi-hidden {
		visibility: hidden;
	}

	input {
		width: 80%;
	}

	.pepole {
		width: 55%;
		margin-right: 34px;
		text-align: right;
	}

	radio {
		padding-right: 20upx;
	}

	.tips {
		margin-top: 40upx;
		color: #666;
		font-size: 16px;
		padding: 0 30upx;
	}

	.btn-area {
		margin: 20upx 30upx;
	}

	.submit-btn {
		background-color: #f94c48;
		color: #fff;
		letter-spacing: 5px;
	}

	picker {
		width: 100%;
	}

	.weui-cell__hd {
		display: flex;
		width: 38%;
		align-items: center;
	}

	.weui-cell__hdhd {
		display: flex;
		justify-content: space-between;
		width: 100%;
		color: #999;
		font-size: 14px
	}

	.weui-cell__hdhd .weui-cell__hdhd_left,
	.weui-cell__hdhd_right {
		font-size: 16px;
		display: flex;
		flex-direction: column;
		width: 45%;
		justify-content: center;
	}

	.weui-cell__hdhd_right {
		margin-left: 65px;
		width: 33%;
	}

	.weui-cell__hdhd_left text:nth-of-type(2) {
		color: green;
	}

	.weui-cell__bd {
		color: #666;
	}

	.weui-cell__bd-ad {
		display: flex;
		align-items: center;
		width: 70%;
		justify-content: flex-end;

	}

	.weui-cell__bd-hd {
		margin-right: 40upx;
		width: 72%;
		display: flex;
		align-items: center;
		justify-content: flex-start;
	}

	.weui-cell__yes {
		width: 30%;
		font-size: 30upx;
	}

	textarea {
		width: auto;
		height: 180upx;
	}

	.weui-cell__hdhd_right_text {
		display: flex;
		align-items: center;
		justify-content: space-between;
	}

	.radio {
		display: block;
		border-top: 1px solid #ddd;
		padding: 5px;
	}

	.weui-cell__hdhd_right_text .boxB {
		width: 57%;
		color: #f94c48;
		font-size: 36upx;
		text-align: center;
	}

	.weui-cell__hdhd_right_text .boxA,
	.weui-cell__hdhd_right_text .boxC {
		width: 20upx;
		height: 20upx;
		padding: 10upx;
		font-size: 32upx;
		text-align: center;
		line-height: 20upx;
		background-color: #ff9999;
		color: #000;
	}

	.upload-title {
		color: #333;
	}

	/* 施工内容 */
	.weui-textarea-bt {
		position: absolute;
		top: 40%;
		left: 5%;
	}

	.weui-textarea-bt-show {
		display: none;
	}

	.weui-textarea-bt-hide {
		display: block;
	}

	.weui-textarea-bt .text {
		padding: 6upx 20upx;
		margin-right: 20upx;
		border-radius: 16upx;
		background-color: #999999;
		color: #fff;
		font-size: 20upx;
	}

	/* 工种选择 */

	.workers-type-wrap {
		display: flex;
		flex-wrap: wrap;
	}

	.workers-type {
		width: 31%;
		box-sizing: border-box;
		padding: 20upx 20upx;
		color: #666;
		border: 1px solid #ccc;
		border-radius: 5px;
		margin: 0 1.167%;
		margin-bottom: 20upx;
		text-align: center;
		font-size: 28upx;
	}

	.workers-type-choose {
		background-color: #f94c48;
		color: #fff;
		border: 1px solid #f94c48;
	}

	/* 开工时间 */

	.start-date-picker2 {
		margin-left: 10upx;
	}

	.detail-picker {
		/* text-align: right; */
		width: 100%;
	}

	.pd-r-0 {
		padding-right: 0;
	}

	.loc-img-wrap {
		display: flex;
		align-items: center;
		margin-right: -15upx;
	}

	.loc-image {
		width: 50upx;
		height: 50upx;
	}

	.color-333 {
		color: #333;
	}

	.small-size {
		font-size: 28upx;
		flex-wrap: wrap;
	}

	.ml-23 {
		margin-left: 23upx;
	}

	.worker-type-radio {
		width: 50%;
		box-sizing: border-box;
		margin-bottom: 20upx;
	}

	/* 施工队可抢单地区 */

	checkbox {
		display: none;
	}

	.order-region {
		border: 1px solid #e5e5e5;
		padding: 5upx 20upx;
		border-radius: 5px;
		margin-right: 20upx;
	}

	.order-region-active {
		border: 1px solid #f94c48;
		background-color: #f94c48;
		color: #fff;
	}

	/*图片尺寸修改*/

	.weui-uploader__input-box {
		width: 216upx;
		height: 216upx;
		margin-right: 0;
	}

	/* .weui-uploader__file>view{
	  width: 216upx;
	  height: 216upx;
	} */

	.weui-uploader__img {
		width: 216upx;
		height: 216upx;
		border: 1px solid #d9d9d9;
	}

	/* .weui-uploader__files .weui-uploader__file{
	  margin-right: 13px;
	} */

	.weui-uploader__files .weui-uploader__file:nth-child(3n) {
		margin-right: 0;
	}

	.weui-uploader__bd>.weui-uploader__file {
		margin-right: 0px;
	}

	.weui-uploader__file {
		margin-bottom: 13px;
	}

	.weui-navbar__title {
		font-size: 32upx;
		font-weight: 600;
		padding: 10upx 15upx 0 0;
	}

	.big-size {
		font-size: 22px;
	}


	/* checkbox 修改默认样式 */
	checkbox .wx-checkbox-input {
		width: 40upx;
		height: 40upx;

	}

	checkbox .wx-checkbox-input.wx-checkbox-input-checked {
		background: #f94c48;
	}

	checkbox .wx-checkbox-input.wx-checkbox-input-checked::before {
		width: 40upx;
		height: 40upx;
		line-height: 40upx;
		text-align: center;
		font-size: 36upx;
		color: #fff;
		background: transparent;
		transform: translate(-50%, -50%) scale(1);
		-webkit-transform: translate(-50%, -50%) scale(1);
	}

	.weui-navbar__slider {
		width: 5.8em;
	}

	.weui-navbar__item {
		display: inline-block;
	}

	.f24 {
		font-size: 24upx;
	}

	.fr {
		float: right;
		overflow: hidden;
	}

	.color999 {
		color: #999;
	}

	.input-r {
		text-align: right;
	}

	.lv-color {
		color: #009900;
		margin-left: 20upx;
	}

	.header-tab {
		padding: 0;
		height: 100upx;
		line-height: 100upx;
		border-bottom: 1px solid #000000;
	}

	.dis-hd {
		display: flex;
		align-items: center;
	}

	.mar-top20 {
		margin-top: 20upx;
	}

	.check-pop {
		position: absolute;
		top: 0;
		left: 0;
		width: 100%;
		height: 100%;
		display: flex;
		align-content: center;
		justify-content: center;
		z-index: 998;
	}

	.check-cover {
		width: 100%;
		height: 100%;
		background-color: #000;
		opacity: .5;
		z-index: 99;
	}

	.check-succ {
		background-color: #fff;
		border-radius: 5px;
		position: absolute;
		top: 10%;
		left: 10%;
		width: 80%;
		height: 700upx;
		display: flex;
		flex-direction: column;
		align-content: center;
		z-index: 999;
	}

	.check-slose {
		position: absolute;
		top: 3%;
		right: 3%;
	}

	.check-slose>image {
		width: 40upx;
		height: 40upx;
	}

	.check-succ-header {
		width: 120upx;
		height: 120upx;
		margin: 20upx auto;
	}

	.check-succ-header>image {
		width: 100%;
		height: 100%;
	}

	.check-succ-tit {
		text-align: center;
		font-size: 34upx;
		font-weight: 600;
	}

	.check-succ-red,
	.check-succ-accept {
		display: flex;
		align-items: center;
		justify-content: center;
		margin: 30upx 30upx 0upx;
		padding: 20upx;
		height: 30%;
		background-color: #f3f1f2;
		border-radius: 5upx;
		font-size: 28upx;
	}

	.check-succ-red>image {
		width: 80upx;
		height: 100upx;
		margin-right: 20upx;
	}

	.check-succ-accept>image {
		width: 160upx;
		height: 80upx;
		margin-right: 20upx;
	}

	.check-succ-nav {
		width: 100%;
		height: 200upx;
		background-color: #f94c48;
		display: flex;
		align-items: center;
		justify-content: center;
		color: #fff;
		margin-top: 40upx;
	}

	.check-succ-nav>image {
		width: 40upx;
		height: 40upx;
		margin-right: 20upx;
	}

	.pepole {
		width: 55%;
		margin-right: 34px;
		text-align: right;
	}

	.weui-cell__yes {
		width: 30%;
		font-size: 30upx;
	}

	.cont-block {
		display: flex;
		/* min-height: 12vh;
	  max-height: 20vh; */
		height: 10vh;
		border-bottom: 1px solid #e5e5e5;
	}

	.cont-list {
		width: 50%;
		display: flex;
		align-items: center;
		justify-content: center;
		border-right: 1px solid #e5e5e5;
		font-size: 32upx;
		background-color: #ffffcc;
	}

	.cont-list:nth-child(3) {
		border-right: none;
	}

	.cont-list image {
		width: 20upx;
		height: 15upx;
		margin-left: 10upx
	}

	.listActive {
		background-color: #f94c48;
		border-bottom: 1px solid #f94c48;
		color: #fff;
	}

	.nearby {
		padding: 10upx 0;
		background-color: #ebefee;
	}

	.nearby_item_on {
		background-color: #ebefee;
		color: #f94c48;
		opacity: 1;
	}

	.earby-panel {
		padding: 20upx;
	}

	.earby-list {
		width: 100%;
		margin-bottom: 30upx;
		border-radius: 15upx;
		border: 1px solid #e1e1e1;
		background-color: #fff;
		box-shadow: 0px 5px 10px 2px #999;
	}

	.earby-list-top {
		padding: 30upx;
		display: flex;
		align-items: center;
	}

	.earby-list-top-img {
		width: 140upx;
		min-width: 140upx;
		height: 140upx;
	}

	.earby-list-top-img image {
		width: 100%;
		height: 100%;
	}

	.earby-list-top-right {
		margin-left: 20upx;
		width: 100%;
		height: 100%;
	}

	.earby-list-top-right-name {
		display: flex;
		align-items: center;
	}

	.craft {
		font-size: 24upx;
		padding: 4upx 20upx;
		border: 1px solid #f94c48;
		border-radius: 90upx;
		margin-right: 20upx;
	}

	.earby-list-top-right-level {
		margin: 6upx 0;
	}

	.earby-list-top-right-host {
		display: flex;
		align-items: center;
		font-size: 24upx;
	}

	.earby-list-top-right-host image {
		width: 40upx;
		height: 40upx;
	}

	.name-auto {
		max-width: 200upx;
		overflow: hidden;
		white-space: nowrap;
		text-overflow: ellipsis;
		margin-right: 20upx;
	}

	.mar-auto {
		width: 330upx;
		overflow: hidden;
		white-space: nowrap;
		text-overflow: ellipsis;
		margin-right: auto;
	}

	.earby-list-bottom {
		width: 100%;
		height: 80upx;
		display: flex;
		border-top: 1px dashed #e6e6e6;
	}

	.earby-list-bottom-list {
		width: 33.3%;
		display: flex;
		align-items: center;
		justify-content: center;
		border-right: 1px dashed #e6e6e6;
	}

	.earby-list-bottom-list:nth-child(3) {
		border-right: none;
	}

	/* .earby-list-bottom-list:nth-child(1){
	  background-color:#F94C48;
	} */
	.earby-list-bottom-list image {
		width: 40upx;
		height: 40upx;
		margin-left: 10upx;
	}

	.earby-list-bottom-list .img {
		height: 30upx;
	}

	.weui-navbars {
		display: flex;
		border-bottom: 1px solid #a9a9a9;
	}

	.weui-navbar-list {
		background-color: #eaefeb;
		width: 33.3%;
		height: 80upx;
		display: flex;
		align-items: center;
		justify-content: center;
		font-size: 32upx;
		font-weight: 600;
	}

	.navbar-act {
		color: #f94c48;
	}

	.square {
		display: inline-block;
		width: 40upx;
		height: 40upx;
		border: 1px solid #666;
		margin-right: 20upx;
	}

	.mytick {
		display: inline-block;
		position: relative;
		width: 40upx;
		height: 40upx;
		background-color: #f94c48;
		border: 1px solid #f94c48;
		margin-right: 20upx;
	}

	.mytick:before,
	.mytick:after {
		content: '';
		pointer-events: none;
		position: absolute;
		color: #fff;
		border: 2px solid #fff;
		background-color: #fff;
	}

	.mytick:before {
		width: 1px;
		height: 0px;
		left: 20%;
		top: 50%;
		transform: skew(0deg, 50deg);
	}

	.mytick:after {
		width: 4px;
		height: 0px;
		left: 40%;
		top: 40%;
		transform: skew(0deg, -50deg);
	}

	.earby-list-bottom button {
		line-height: 0;
		padding: 0;
		background-color: #fff;
	}

	.weui-tab {
		position: relative;
	}

	.navbar-banner {
		padding: 20upx 20upx 0 20upx;
		height: 200upx;
		margin-top: 10upx;
	}

	.navbar-banner image {
		width: 100%;
		height: 100%;
		border-radius: 15upx;
	}

	/* 群组 */
	.room-box {
		width: 95%;
		height: 300upx;
		border-radius: 10upx;
		margin-left: 2.5%;
		margin-top: 20upx;
		background: white;
		align-items: center;
	}

	.left {
		width: 35%;
		height: 85%;
		margin-left: 20upx;
	}

	.right {
		width: 63%;
		height: 85%;
		margin-right: 20upx;
	}

	.room-title {
		width: 100%;
		height: 20%;
		font-size: 30upx;
		font-weight: 800;
		margin-left: 10upx;
		text-overflow: ellipsis;
	}

	.room-img {
		width: 85%;
		height: 80%;
		margin-left: 10upx;
	}

	.swiper {
		height: 100%;
		width: 100%;
	}

	.swiper image {
		height: 100%;
		width: 100%;
	}

	.right-imgs {
		width: 100%;
		height: 100%
	}

	.card {
		width: 100%;
		height: 520upx;
		position: relative;
	}

	.card-img {
		width: 100%;
		height: 100%;
		z-index: -1;
	}

	.card-block {
		position: absolute;
		top: 0;
		left: 0;
		width: 100%;
		height: 80%;
	}

	.block-head-img {
		width: 180upx;
		height: 180upx;
		border-radius: 50%;
		margin-right: 20upx;
	}

	.card-block-head {
		border-radius: 15upx;
		margin: 20upx 20upx 10upx 20upx;
		background-color: white;
		display: flex;
		padding: 10upx 20upx 20upx 25upx;
		flex-direction: column;
	}

	.card-block-head-top {
		display: flex;
		align-items: center;
		height: 230upx;
		width: 100%;
	}

	.block-head-user {
		width: 70%;
		color: #fff;
		margin-top: 30upx;
	}

	.block-head-user-name {
		width: 100%;
		display: flex;
		flex-direction: column;
		height: 110upx;
		font-size: 36upx;
		font-weight: 600;
	}

	.block-head-user-name-title {
		max-width: 100%;
		white-space: nowrap;
		font-size: 36upx;
		color: black;
	}

	.user-level-img {
		display: inline-block;
	}

	.icon-star {
		width: 36upx;
		height: 36upx;
	}

	.card-block-head-address {
		height: 100upx;
		display: flex;
		align-items: flex-end;
		color: #fff;
		font-size: 32upx;
	}

	.address-card-name {
		width: 90%;
		margin-right: auto;
		overflow: hidden;
		text-overflow: ellipsis;
		white-space: nowrap;
		line-height: 1;
		color: black;
	}

	.address-card-host {
		width: 36upx;
		height: 48upx;
		margin-right: 20upx;
	}

	.address-card-wx {
		position: absolute;
		top: 40upx;
		right: 50upx;
		width: 80upx;
		height: 80upx;
		z-index: 9;
	}

	.block-head-user-workCategory text {
		border: 1px solid #FFB02D;
		display: inline-block;
		padding: 2upx 20upx;
		margin: 18upx 20upx 10upx 0;
		border-radius: 15upx;
		color: black;
	}

	.card-block-brief {
		margin: 0 20upx;
		padding-bottom: 20upx;
	}

	.card-block-brief-head {
		height: 60upx;
		margin: 10upx 0;
		display: flex;
		align-items: center;
		color: #FFB02D;
	}

	.card-block-brief-img {
		width: 30upx;
		height: 40upx;
		margin-right: 20upx;
	}

	.card-block-brief-intr {
		margin: 20upx 20upx 0;
		color: #FFB02D;
		text-overflow: -o-ellipsis-lastline;
		overflow: hidden;
		text-overflow: ellipsis;
		display: -webkit-box;
		-webkit-line-clamp: 2;
		line-clamp: 2;
		-webkit-box-orient: vertical;
	}

	.card-line-btn {
		padding: 20upx;
		padding-bottom: 0upx;
		display: flex;
	}

	.line-btn-editinfo {
		width: 35%;
		height: 80upx;
		display: flex;
		align-items: center;
		justify-content: center;
		border-radius: 15upx;
		color: #fff;
		background-color: #666666;
		margin-right: 2%;

	}

	.line-btn-editinfo image {
		width: 40upx;
		height: 40upx;
		margin-right: 20upx;
	}

	.line-btn-card {
		width: 35%;
		height: 80upx;
		line-height: 80upx;
		padding: 0;
		border-radius: 15upx;
		background-color: #656565;
		display: flex;
		align-items: center;
		justify-content: center;
		color: white;
	}

	.line-btn-card image {
		width: 40upx;
		height: 40upx;
		margin-right: 20upx;
	}

	.line-btn-collect {
		width: 26%;
		height: 80upx;
		margin-right: 2%;
		display: flex;
		align-items: center;
		justify-content: center;
		border-radius: 15upx;
		background-color: #666666;
		color: white;
	}

	.line-btn-collect image {
		width: 32upx;
		height: 32upx;
		margin-right: 20upx;
	}

	.btn-pay-service-yq {
		background-color: #F8EAD0;
		width: 60%;
		height: 91upx;
		line-height: 86upx;
		position: relative;
		font-size: 31upx;
		text-align: right;
		padding-right: 13upx;
		margin-left: 30upx;
		font-weight: 400;

	}

	.btn-pay-service-yq image {
		height: 50upx;
		width: 50upx;
		margin-top: 4upx;
		position: absolute;
		top: 14upx;
		left: 10upx;
	}

	.user-level-text-mobile {
		padding-right: 10upx;
		color: black;
		font-size: 45upx;
	}

	.cont-list .newstabBar {
		text-align: center;
		height: 90upx;
	}

	.cont-list text:nth-child(1) {
		display: block;
		width: 153upx;
		height: 30upx;
		margin-bottom: 10upx;
	}

	.cont-list text:nth-child(2) {
		display: block;
		width: 153upx;
		height: 30upx;
	}

	.listActiveWhite {
		border-bottom: 5upx solid white;
	}

	.listActive {
		background-color: #f94c48;
		color: #fff;
	}
</style>
